#ifndef __SPACEWAR_GAME_H__
#define __SPACEWAR_GAME_H__

#include <engine.h>
#include "MainWindow.h"

class Background;
class Ship;
class Minimap;
class SpaceWarGame : public GGame
{
	Q_OBJECT

public:
	SpaceWarGame();
	~SpaceWarGame();

	QWidget*	mainWindow();

	virtual void	Update(double elapsed);
	virtual bool	GameInitialize();
	virtual void	ProcessKeyEvent(QKeyEvent* event);

	//const QSize&	GetWorldSize();
	const QSize&	GetWorldSize();
	QRect			GetScreenRectToWorld() const;

private:
	//Ui::SpaceWarClass ui;
	QElapsedTimer	m_elapT;
	double			m_ds;

	MainWindow		m_mainWindow;
	Background		*m_pBg;
	Ship			*m_pShip;
	Minimap			*m_pMinimap;
	
	QSize			m_world, m_screen;
	double			m_world_x, m_world_y;
};

#endif //__SPACEWAR_GAME_H__
